export default {
  'POST /admin/target-list': (req,res) => {
    let { page, limit } = req.body;
    page = +page;
    limit = +limit;
    const pageIndex = (page-1) * limit + 1
    setTimeout(() => {
      res.json({
        code: 200,
        data: {
          totalCount: 100,
          list: Array.from({ length: 20}).map((item,i) => {
            return {
              "id": pageIndex + i,
              tokenID: 1,
              targetTypeID: 1,
              "displayName": "指标显示名称" + (pageIndex + i),
              "metricName": "指标公制名称",
              "tokenName": "BTC", // 币种名称
              "targetTypeName": "指标类型名称",
              "symbol": "BTC",
              "tokenAddr": "fewfwefewfwefwe",// 合约地址
              "createdTime": 1622400065,
              "desc": '<p style="color: green">测试富文本</p>'
            }
          })
        }
      })
    },500)
  },
  'POST /admin/add-target': (req,res) => {
    setTimeout(() => {
      res.json({
        "code": 200,
        "message": "OK",
        "data": true
      })
    },500)
  },
  'POST /admin/update-target/:id': (req,res) => {
    setTimeout(() => {
      res.json({
        "code": 200,
        "message": "OK",
        "data": true
      })
    },500)
  },
  'POST /admin/delete-target/:id': (req,res) => {
    setTimeout(() => {
      res.json({
        "code": 200,
        "message": "OK",
        "data": true
      })
    },500)
  },
  'POST /admin/relation-package-target':  (req,res) => {
    setTimeout(() => {
      res.json({
        "code": 200,
        "message": "OK",
        "data": true
      })
    },500)
  },
}
